package com.example.springbootdemo.user;

import lombok.Data;

@Data
public class Ret {
    private int code;
    private String msg;
    private Object data;

    public static Ret suc(Object o) {
        Ret t = new Ret();
        t.code = 200;
        t.data = o;
        t.msg = "succ";
        return t;
    }
    public static Ret fail(String msg) {
        Ret t = new Ret();
        t.code = 500;
        t.msg = "fail-" + msg;
        return t;
    }
}
